Skip to content

Introduce JCasC configuration history tracking via listener extension point#2820

Closed
somiljain2006 wants to merge 4 commits intojenkinsci:masterfrom
somiljain2006:Configuration-history-implementation
Closed

Introduce JCasC configuration history tracking via listener extension point#2820
somiljain2006 wants to merge 4 commits intojenkinsci:masterfrom
somiljain2006:Configuration-history-implementation

Conversation

@somiljain2006
Copy link
Copy Markdown
Contributor

@somiljain2006 somiljain2006 commented Apr 8, 2026

Fixes #955

Introduce support for tracking and viewing JCasC configuration history directly from the Jenkins UI. This change adds a CasCReloadListener extension point that is triggered after a successful JCasC application, allowing external components to react to configuration changes. A pluggable JCasCHistoryBackend abstraction is introduced, with a LocalFileHistoryBackend Implementation that stores configuration snapshots under the Jenkins home directory.

  • Stores jenkins.yaml snapshots along with metadata (history.xml)
  • Captures the user responsible for the change (or SYSTEM during startup)
  • Implements a snapshot-based history model
  • Enforces a retention policy (default: 50 entries)
  • Handles timestamp collisions via suffix fallback
  • Provides a ManagementLink UI to browse history and view snapshots
  • Includes test coverage for storage, retention, concurrency, and ordering
Screenshot 2026-04-08 at 9 09 37 PM Screenshot 2026-04-08 at 9 11 34 PM

Your checklist for this pull request

🚨 Please review the guidelines for contributing to this repository.

  • Make sure you are requesting to pull a topic/feature/bugfix branch (right side) and not your master branch!
  • Ensure that the pull request title represents the desired changelog entry
  • Please describe what you did
  • Link to relevant issues in GitHub or in Jenkins JIRA
  • Link to relevant pull requests, esp. upstream and downstream changes
  • Did you provide a test case? That demonstrates a feature that works or fixes the issue.

@somiljain2006 somiljain2006 requested a review from a team as a code owner April 8, 2026 18:55
Copy link
Copy Markdown
Member

@timja timja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most people use SCM for this, I don't think there's much point retaining this especially not shipping it built-in

for feature requests better to look at the most recently updated ones.

a bunch of the old feature requests were good ideas when the plugin was created but if there's no need for them now its just more code to maintain in the future better to limit our surface to what problems are actually facing

@somiljain2006 somiljain2006 deleted the Configuration-history-implementation branch April 9, 2026 10:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

JCasC Configuration History: New feature or Plugin

3 participants